package com.example.sup.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 
 * @TableName electricity_consumption_info
 */
@TableName(value ="electricity_consumption_info")
@Data
public class ElectricityConsumptionInfo implements Serializable {
    /**
     * 用电量统计信息表
     */
    @TableId(type = IdType.AUTO)
    private Integer electricityConsumptionId;

    /**
     * 线路id
     */
    private Integer jackId;

    /**
     * 耗电量 毫安
     */
    private Integer electricityConsumption;

    /**
     * 监区id
     */
    private Integer prisonDistrictId;

    /**
     * 设备id
     */
    private Integer equipmentId;

    /**
     * 预留字段1
     */
    private String reservedFields1;

    /**
     * 预留字段2
     */
    private String reservedFields2;

    /**
     * 
     */
    private Date createTime;

    /**
     * 
     */
    private String createBy;

    /**
     * 
     */
    private Date updateTime;

    /**
     * 
     */
    private String updateBy;

    /**
     * 设备名称
     */
    private String equipmentName;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ElectricityConsumptionInfo other = (ElectricityConsumptionInfo) that;
        return (this.getElectricityConsumptionId() == null ? other.getElectricityConsumptionId() == null : this.getElectricityConsumptionId().equals(other.getElectricityConsumptionId()))
            && (this.getJackId() == null ? other.getJackId() == null : this.getJackId().equals(other.getJackId()))
            && (this.getElectricityConsumption() == null ? other.getElectricityConsumption() == null : this.getElectricityConsumption().equals(other.getElectricityConsumption()))
            && (this.getPrisonDistrictId() == null ? other.getPrisonDistrictId() == null : this.getPrisonDistrictId().equals(other.getPrisonDistrictId()))
            && (this.getEquipmentId() == null ? other.getEquipmentId() == null : this.getEquipmentId().equals(other.getEquipmentId()))
            && (this.getReservedFields1() == null ? other.getReservedFields1() == null : this.getReservedFields1().equals(other.getReservedFields1()))
            && (this.getReservedFields2() == null ? other.getReservedFields2() == null : this.getReservedFields2().equals(other.getReservedFields2()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getEquipmentName() == null ? other.getEquipmentName() == null : this.getEquipmentName().equals(other.getEquipmentName()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getElectricityConsumptionId() == null) ? 0 : getElectricityConsumptionId().hashCode());
        result = prime * result + ((getJackId() == null) ? 0 : getJackId().hashCode());
        result = prime * result + ((getElectricityConsumption() == null) ? 0 : getElectricityConsumption().hashCode());
        result = prime * result + ((getPrisonDistrictId() == null) ? 0 : getPrisonDistrictId().hashCode());
        result = prime * result + ((getEquipmentId() == null) ? 0 : getEquipmentId().hashCode());
        result = prime * result + ((getReservedFields1() == null) ? 0 : getReservedFields1().hashCode());
        result = prime * result + ((getReservedFields2() == null) ? 0 : getReservedFields2().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getEquipmentName() == null) ? 0 : getEquipmentName().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", electricityConsumptionId=").append(electricityConsumptionId);
        sb.append(", jackId=").append(jackId);
        sb.append(", electricityConsumption=").append(electricityConsumption);
        sb.append(", prisonDistrictId=").append(prisonDistrictId);
        sb.append(", equipmentId=").append(equipmentId);
        sb.append(", reservedFields1=").append(reservedFields1);
        sb.append(", reservedFields2=").append(reservedFields2);
        sb.append(", createTime=").append(createTime);
        sb.append(", createBy=").append(createBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", equipmentName=").append(equipmentName);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}